package co.edu.usbcali.egrapico.vista.tools;

import co.edu.usbcali.egrapico.vista.ambient.LabelRestriction;
import co.edu.usbcali.egrapico.vista.ambient.PanelPrecedent;

public class JPanelTranferHandlerPrecedent extends StringTransferHandler {

    protected void importString(javax.swing.JComponent c, String str) {
        PanelPrecedent target = (PanelPrecedent) c;
        try {
            target.setSelected(true);
        } catch (java.beans.PropertyVetoException e) {
        }
        javax.swing.ImageIcon I0 = new javax.swing.ImageIcon(getClass().getResource("/co/edu/usbcali/egrapico/images/genericRestriction.gif"));
        LabelRestriction labe0 = new LabelRestriction();
        if (str.equals("Generic Restriction")) {
            labe0.setIcon(I0);
            labe0.setHorizontalTextPosition(javax.swing.JLabel.CENTER);
            labe0.setVerticalTextPosition(javax.swing.JLabel.BOTTOM);
            labe0.setName("Restriction");
            labe0.setIsOfObject(false);
            labe0.setLocation(target.getLPane().getMousePosition());
            labe0.setSize(80, 80);
            target.addLayeredPane(labe0);
        }
    }
}